'use strict';

const Controller = require('egg').Controller;

class ProductController extends Controller {
    //获取商品
    async getProduct() {
        let {ctx,service} = this;
        let {id} = ctx.query;
        let list = await service.product.getProduct(id);
        ctx.body = {
            code:1,
            data:list
        }
    }
}

module.exports = ProductController;
